<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<script src="js/vue.js"></script>
	</head>
	<body>
		<div id="app">
			<stu>
				<!-- 缩写 -->
				<template #s2="n2">
					<h5>{{n2.n1}}中秋快乐,放假三天</h5>
				</template>
			</stu>
		</div>
		<template id="stu">
			<div>
				<h3>学生组件</h3>
				<!-- 插槽 -->
				<slot name="s2" :n1="name"></slot>
			</div>
		</template>
		<script type="text/javascript">
			const vm = new Vue({
				el: '#app',
				components: {
					stu: {
						template: '#stu',
						data() {
							return {
								name: '张三'
							}
						}
					}
				},

			});
			console.dir(vm);
		</script>
	</body>
</html>
